from google.appengine.ext import webapp
from google.appengine.ext.webapp import util
from string import Template
from google.appengine.ext import db
import header
import footer
import httplib, urllib

from Functions import Functions


import time
import datetime
import header
import footer
import urllib2
import simplejson
#import json

class Tweet_model(db.Model):
	id_str = db.StringProperty()
	screen_name = db.StringProperty()
	place = db.StringProperty()
	geo = db.StringProperty()
	in_reply_to_user_id_str = db.StringProperty()
	coordinates = db.StringProperty()
	created_at = db.DateTimeProperty()
	retweet_count = db.IntegerProperty()
	retweeted = db.BooleanProperty()
	id_long = db.IntegerProperty()
	text = db.StringProperty()
	
class GeoTweet_model(db.Model):
	#"created_at":"Sat, 26 Nov 2011 20:33:16 +0000",
	screen_name = db.StringProperty()
	id_str = db.StringProperty()
	real_name = db.StringProperty()
	geo = db.StringProperty()
	location = db.StringProperty()
	created_at = db.DateTimeProperty()
	text = db.StringProperty()

class GML:	#GoogleMapLocation
		lat = str()
		lng = str()
		icon = str() 
		gml_id = str()
		name = str()
		rating = float()
		reference = str()
		vicinity = str()
		hootscore = int()
      
		def __init__(self, lat=None, lng=None, icon=None, gml_id=None, name=None, rating=0, reference=None, vicinity=None, hootscore=0 ):
			self.lat= lat
			self.lng= lng
			self.icon = icon
			self.gml_id = gml_id
			self.name = name
			self.rating = rating
			self.reference = reference
			self.vicinity = vicinity
			self.hootscore = hootscore
